import os
import webapp2
import jinja2

jinja_environment = jinja2.Environment(
    loader=jinja2.FileSystemLoader(os.path.join(os.path.dirname(__file__),'templates')))

class MainPage(webapp2.RequestHandler):

    def get(self):
        self.render_template('index.html')

    def render_template(self, filename):
        template_values = {
            'name': 'main',
        }
        template = jinja_environment.get_template(filename)
        self.response.out.write(template.render(template_values))

app = webapp2.WSGIApplication([
    ('/', MainPage)
], debug=True)

